﻿using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;

namespace Huasky.Rest;

public class MainDbContext: DbContext
{
    public DbSet<Student> Students { get; set; }

    protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
    {
        optionsBuilder.UseInMemoryDatabase("My-Rest");
    }
}



public class Student
{
    [Key]
    public int Id { get; set; }

    public string Name { get; set; }

    public string Code { get; set; }

    public int Age { get; set; }
}
